package testPublishPkg

func Try(fun func(), handler func(interface{})) {
	// 异常的捕获
	defer func() {
		if err := recover(); err != nil {
			handler(err)
		}
	}()
	// 执行正常的逻辑
	fun()
}
